import { defineComponent, shallowRef } from 'vue'

export default defineComponent({
  name: 'customPrompt',
  setup(_, { expose }) {
    const visible = shallowRef(false)

    const show = () => {
      visible.value = true
    }

    const hide = () => {
      visible.value = false
    }

    expose({
      show,
      hide,
    })

    return () => (
      <>
        <a-modal v-model:open={visible.value} title="自定义" centered>
          <p>Some contents...</p>
          <p>Some contents...</p>
          <p>Some contents...</p>
        </a-modal>
      </>
    )
  },
})
